//
//  BaseModel.h
//  JYShop
//
//  Created by 花花 on 2017/9/28.
//  Copyright © 2017年 花花. All rights reserved.
//

#import <Foundation/Foundation.h>

@class JYDepositObjModel;
@interface BaseModel : NSObject


@property(nonatomic,copy)NSString *id; //商品ID

@property(nonatomic,copy)NSString *name; //商品名称

//@property(nonatomic,copy)NSString *description; //描述

@property(nonatomic,copy)NSString *image; //图片

@property(nonatomic,copy)NSString *unit; //单位

@property(nonatomic,assign)NSInteger label; //标签 1：热门、2：精品 3、新品

@property(nonatomic,copy)NSString *categoryName; //分类名称

@property(nonatomic,copy)NSString *originalPrice; //原价

@property(nonatomic,copy)NSString *price; //单价

@property(nonatomic,assign)NSInteger market; //市场价

@property(nonatomic,assign)NSInteger collect; //是否收藏

@property(nonatomic,copy)NSString *categoryId;

@property(nonatomic,assign)NSInteger goodsAmount; //元宝

@property(nonatomic,copy)NSString *spec;


@property(nonatomic,assign)NSInteger amount; //波波


@property(nonatomic,strong)NSString *depositObj;


//字典转模型
+ (instancetype)objectWithDic:(NSDictionary*)dic;

+ (NSArray*)objectsInArray:(NSArray<NSDictionary*>*)arr;

- (void)setValue:(id)value forUndefinedKey:(NSString *)key;
@end


/*
 depositObj =                 {
 amount = 0;
 categoryId = "<null>";
 categoryName = "<null>";
 collect = 0;
 deposit = "<null>";
 depositObj = "<null>";
 description = "\U4e70\U597d\U83dc\U4e0a\U4eca\U4f18";
 id = 2;
 image = "https://www.baidu.com/img/baidu_jgylogo3.gif";
 market = 2;
 name = "\U54c8\U5bc6\U74dc-88\U53f7";
 originalPrice = "<null>";
 pcategoryId = "<null>";
 price = 2;
 sales = 2;
 spec = "\U5143/\U8fd1";
 };

 */
@interface JYDepositObjModel : NSObject

/*******************波波*********************/
@property(nonatomic,copy)NSString *amount;


@property(nonatomic,copy)NSString *categoryId;


@property(nonatomic,copy)NSString *id;



@property(nonatomic,copy)NSString *image;


@property(nonatomic,copy)NSString *name;


@property(nonatomic,copy)NSString *originalPrice;


@property(nonatomic,copy)NSString *price;


@property(nonatomic,copy)NSString *spec; //斤




/*******************元宝*********************/
//
/*
 
 goodsAmount = 0;
 goodsDesc = "<null>";
 goodsId = 2;
 goodsName = XXXXXXXXXXXXXXXx;
 goodsPictureUrl = "http://pic.jinyoufarm.com/72df0411.jpg";
 goodsPrice = 2;
 originalPrice = 0;
 unit = "\U65a4";
 
 */

@property(nonatomic,copy)NSString *goodsAmount;


@property(nonatomic,copy)NSString *goodsName;


@property(nonatomic,copy)NSString *goodsId;



@property(nonatomic,copy)NSString *goodsPictureUrl;


@property(nonatomic,copy)NSString *goodsPrice;


@property(nonatomic,copy)NSString *unit;






@end
